home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / lists / mint / l_0399 / 74 < prev    next >
Internet Message Format  |  1994-08-27  |  2KB

  1. From: mh1@irz.inf.tu-dresden.de (Michael Hohmuth)
  2. Subject: RE: Environment variables
  3. Date: Sun, 7 Feb 93 11:04:37 MET
  4. In-Reply-To: <9301292240.AA10401@acae127.cadence.com>; from "jwahar r. bammi" at Jan 29, 93 5:40 pm
  5. Mime-Version: 1.0
  6.  
  7. > > What I want is to convert _all_ environment variables (which contain 
  8. > > file names/paths) to the Unix form in the startup code (not just the PATH 
  9. > > variable), and convert it back when spawning. To prevent environment 
  10. >     sorry if i misunderstood, but how do you determine when the value of
  11. > an environment variable contains directory paths (other than PATH which has
  12. > predefined semantics) ?
  13.  
  14. The scheme I have in mind tries to do this "intelligently". I imagine 
  15. something like this:
  16.  
  17. Viariables that do not contain paths are treated "specially". When a program
  18. starts, it determines which variables are "special" by reading a certain
  19. environment variable we define (e.g. "SPECIAL"), which contains the names
  20. of all "special" environment variables: for instance: 
  21.  
  22.     SPECIAL=UNIXMODE,FUBAR
  23.  
  24. This would declare the UNIXMODE and FUBAR environment variables to be treated
  25. specially, which means that no path conversion is done for these variables.
  26. Additionally, any environment variable which already contains "/", and any
  27. variable which is set (putenv()) to something containing a backslash, are
  28. added to the SPECIAL list, which would also be exported when spawning.
  29.  
  30. Would this be too much trouble?
  31.  
  32. Michael
  33. -- 
  34. Internet: hohmuth@freia.inf.tu-dresden.de
  35.